package com.bluesky.plum.uimodels.render.swing.components.containers;

import javax.swing.JComponent;
import javax.swing.JPanel;

import com.bluesky.plum.uimodels.standard.UIComponent;

public class SPanel extends
		com.bluesky.plum.uimodels.standard.components.containers.Panel {
	JPanel panel;

	public SPanel() {
		panel = new JPanel();

	}

	@Override
	public Object getNativeComponent() {

		return panel;
	}

	
	@Override
	public void addChildComponent(UIComponent uic) {
		
		super.addChildComponent(uic);
		
		panel.add((JComponent)uic.getNativeComponent());
	}
	
	@Override
	public void removeAllChildren() {
		
		super.removeAllChildren();
		
		panel.removeAll();
	}

}
